package com.indusfo.spc.pojo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.indusfo.spc.common.pojo.BasePojo;
import lombok.Getter;
import lombok.Setter;

import javax.persistence.Transient;
import java.util.Date;

/**
 * @author chenm
 * @Description 工艺文件明细
 * @create 2019-11-27 9:39
 */
@Getter
@Setter
public class ProfileDetail extends BasePojo {
  private static final long serialVersionUID = 1L;
/*
  工艺文件明细id
  */
  private Integer profileDetailId;
  /*
  工艺文件id
  */
  private Integer profileId;
/*
  产品/物料id
  */
  private Integer matId;
/*
  工序id
  */
  private Integer proId;
  /*
  物料版本id
  */
  private Integer matVerId;
/*
  文件名
  */
  private String content;

  /*
  文件路径
  */
  private String relUrl;


  /*
  唯一标识符
  */
  private String uuid;

  /*
    创建日期
  */
  @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  private Date createDate;
  /*
    修改日期
  */
  @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  private Date modifyDate;
  /*
    备注
  */
  private String remark;

  /*
  状态
*/
  private Integer dataState;
  /**
   * 工序名称
   */
  @Transient
  private String proName;
  /**
   * 物料名称
   */
  @Transient
  private String matName;
  /**
   * 物料版本名称
   */
  @Transient
  private String matVerName;
  /**
   * 物料编码
   */
  @Transient
  private String matModel;

  public ProfileDetail() {
  }

  public ProfileDetail(String content, String proName, String matModel) {
    this.content = content;
    this.proName = proName;
    this.matModel = matModel;
  }

  public Integer getProfileDetailId() {
    return profileDetailId;
  }

  public void setProfileDetailId(Integer profileDetailId) {
    this.profileDetailId = profileDetailId;
  }

  public Integer getProfileId() {
    return profileId;
  }

  public void setProfileId(Integer profileId) {
    this.profileId = profileId;
  }

  public Integer getMatId() {
    return matId;
  }

  public void setMatId(Integer matId) {
    this.matId = matId;
  }

  public Integer getProId() {
    return proId;
  }

  public void setProId(Integer proId) {
    this.proId = proId;
  }

  public Integer getMatVerId() {
    return matVerId;
  }

  public void setMatVerId(Integer matVerId) {
    this.matVerId = matVerId;
  }

  public String getContent() {
    return content;
  }

  public void setContent(String content) {
    this.content = content== null ? null : content.trim().replace(" ","");
  }

  public String getRelUrl() {
    return relUrl;
  }

  public void setRelUrl(String relUrl) {
    this.relUrl = relUrl== null ? null : relUrl.trim().replace(" ","");
  }

  public String getUuid() {
    return uuid;
  }

  public void setUuid(String uuid) {
    this.uuid = uuid== null ? null : uuid.trim().replace(" ","");
  }

  public Date getCreateDate() {
    return createDate;
  }

  public void setCreateDate(Date createDate) {
    this.createDate = createDate;
  }

  public Date getModifyDate() {
    return modifyDate;
  }

  public void setModifyDate(Date modifyDate) {
    this.modifyDate = modifyDate;
  }

  public String getRemark() {
    return remark;
  }

  public void setRemark(String remark) {
    this.remark = remark== null ? null : remark.trim().replace(" ","");
  }

  public Integer getDataState() {
    return dataState;
  }

  public void setDataState(Integer dataState) {
    this.dataState = dataState;
  }

  public String getProName() {
    return proName;
  }

  public void setProName(String proName) {
    this.proName = proName;
  }

  public String getMatName() {
    return matName;
  }

  public void setMatName(String matName) {
    this.matName = matName;
  }

  public String getMatVerName() {
    return matVerName;
  }

  public void setMatVerName(String matVerName) {
    this.matVerName = matVerName;
  }

  public String getMatModel() {
    return matModel;
  }

  public void setMatModel(String matModel) {
    this.matModel = matModel;
  }
}
